//
//  UIButton+Extension.swift
//  MicroBlog
//
//  Created by QT on 15/8/2.
//  Copyright © 2015年 綦敦涛. All rights reserved.
//

import UIKit

extension UIButton{
    convenience init(title: String,imgName: String,tColor: UIColor,tFont: CGFloat){
        self.init()
        setTitle(title, forState: UIControlState.Normal)
        setImage(UIImage(named: imgName), forState: UIControlState.Normal)
        setTitleColor(tColor, forState: UIControlState.Normal)
        titleLabel?.font = UIFont.systemFontOfSize(tFont)
    }
    
    convenience init(title: String,BGColor: UIColor){
        self.init()
        setTitle(title, forState: UIControlState.Normal)
        backgroundColor = BGColor
    }
}

